﻿<%@ Page CodeFileBaseClass="AliCMS.Lib.SystemPageBase" %>
<ali:Get ID="Type" Object="Type" InnerID="Request.QueryString['TypeID']" />
<section data-page="type_resource_list" data-title="资源列表" data-lang="<%=ContentLang%>" data-type-id="<%=Request.QueryString["TypeID"]%>">
	<dl class="path1">
		<dt><span>您的位置：</span><a href="../list.aspx?Lang=<%=ContentLang%>" target="ali-navtab">类型列表</a> → <b class="<%=ContentLang%>Font"><%=Type[Name]%></b></dt>
		<dd>
			<select data-ali-widget="combo" data-class="<%=ContentLang%>Font">
				<ali:List Mark="System" Object="Language" Source="Manager.Languages">
					<ali:Record>
						<%If Convert.ToString(Ab) == ContentLang%>
							<option value="<%=Ab%>" selected><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%Else%>
							<option value="<%=Ab%>"><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%EndIf%>
					</ali:Record>
				</ali:List>
			</select>
		</dd>
	</dl>
	<div class="ali-tabs sub-nav" data-height-style="fill" data-event="click">
		<div class="ali-tabs-header">
			<div class="ali-tabs-nav-container">
				<ul>
					<li><a href="../edit.aspx?ID=<%=Request.QueryString["TypeID"]%>" target="ali-navtab">编辑</a></li>
					<li class="ali-active"><a>资源列表</a></li>
					<li><a href="add.aspx?TypeID=<%=Request.QueryString["TypeID"]%>" target="ali-navtab">添加资源</a></li>
				</ul>				
			</div>
		</div>
		<div class="ali-tabs-body">
			<div class="ali-tabs-panel"></div>
			<div class="ali-tabs-panel">
				<form action="?Lang=<%=ContentLang%>&amp;TypeID=<%=Request.QueryString["TypeID"]%>" class="search1">
					文件夹：
					<select name="Folder" data-ali-widget="combo" data-class="<%=ContentLang%>Font">
						<option value="">/</option>
						<ali:List Object="Type.Resource" Operation="ListFolder(Convert.ToInt32(Request.QueryString['TypeID']))">
							<ali:Record>
								<option value="<%=Name%>"><%=Name%></option>
							</ali:Record>
						</ali:List>
					</select>
					<button type="button" class="ali-button" data-operation="DeleteFolder">删除</button>
				</form>
				<div class="content">
					<table data-ali-widget="grid" class="grid1">
						<thead>
							<tr>
								<th>文件名</th>
								<th width="80">删除</th>
							</tr>
						</thead>
						<tbody>
							<ali:List Object="Type.Resource" Operation="ListFile(Convert.ToInt32(Request.QueryString['TypeID']), Request.QueryString['Folder'])" Validate="True">
								<ali:Record>
									<tr data-id="<%=Name%>">
										<td><%=Name%></td>
										<td><a href=""  class="ali-button" data-operation="DeleteFile">删除</a></td>
									</tr>
								</ali:Record>
							</ali:List>			
						</tbody>
					</table>
				</div>				
			</div>
		</div>
		<div class="ali-tabs-bottom"><b></b></div>
	</div>
</section>